Skip to content

Update the Browse Page on CLARK Client#2154

Open
Cwagne17 wants to merge 12 commits intochore/sc-36142/upgrade-angular-from-17-to-18-on-clark-clientfrom
feature/sc-38599/browse-page-modernization
Open

Update the Browse Page on CLARK Client#2154
Cwagne17 wants to merge 12 commits intochore/sc-36142/upgrade-angular-from-17-to-18-on-clark-clientfrom
feature/sc-38599/browse-page-modernization

Conversation

@Cwagne17
Copy link
Contributor

This pull request significantly refactors the browse page UI and logic to provide a more modern, intuitive filtering and sorting experience for users. The changes introduce a sticky filter bar with dropdowns for key filter types, a full-screen modal for filters on mobile, and an updated results grid layout. The filter and sort logic in the component has been reworked for clarity and maintainability, with improved synchronization between UI state and the underlying query object.

UI/UX Improvements:

  • Replaced the sidebar filter layout with a sticky filter bar featuring dropdowns for Topics, Levels, Duration, and Materials, plus a clear filters button and a sort dropdown. A full-screen modal is now used for filters on mobile devices for improved usability. (browse.component.html)

Filter and Sort Logic Refactor:

  • Added state management for filter dropdowns and filter data, including initialization and synchronization with the filter component. Provided methods for toggling dropdowns, updating filter selections, and handling backdrop clicks for modal closure. (browse.component.ts) [1] [2] [3]
  • Refactored the sorting logic to simplify options to "Newest" and "Most Downloaded," removed the "Oldest" and clear sort options, and ensured sort state is properly reflected in the UI and query object. (browse.component.ts) [1] [2]

Query and Pagination Updates:

  • Increased the default and per-page limit for results from 10 to 15 for a denser results grid and updated relevant query logic accordingly. (browse.component.ts) [1] [2]

Filter Reset and Synchronization:

  • Enhanced the clear filters functionality to reset all filter-related fields in the query object and synchronize the UI and filter component state. (browse.component.ts)

These changes collectively modernize the browse experience, streamline filter and sort interactions, and improve maintainability of the codebase.

Screenshot 2026-01-23 at 3 34 16 PM

@Cwagne17 Cwagne17 requested a review from a team January 23, 2026 20:34
@Cwagne17 Cwagne17 self-assigned this Jan 23, 2026
const frameworks = await this.guidelineService.getFrameworks({ limit: 100, page: 1 });
this.frameworkFilter = {
section: 'Guidelines',
section: 'Frameworks',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Image

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dude 😂

<br />
<p>
FILTER BY TAG
<a href="https://forms.gle/j8jp5Qqvm3yxwPei8" target="_blank" class="beta"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This has been here for a little bit too and I have no idea what responses we've got, good time to let it go

<clark-skip-link title="Skip Directly to Learning Objects" skipLocation="results"></clark-skip-link>
<div *ngIf="filters" class="sidebar-wrapper" [ngClass]="{'active': filtersDownMobile}">
<div class="column-title">
<clark-skip-link title="Skip Directly to Learning Objects" skipLocation="results"></clark-skip-link>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure I remember this being here or its purpose

checkDCWFAlignment() {
if (this.learningObject?.guidelines && this.learningObject.guidelines.length > 0) {
this.isDCWFAligned = this.learningObject.guidelines.some(guideline =>
guideline.source &&
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like from the screenshot and the demo you gave us it seemed to work good, wonder if its better to change guideilne.source to guideline.author since author exists on both Frameworks and Search-Index collections. I only see the source attribute in Frameworks and I imagined we'd either be pulling from Guidelines or Search-Index. It should be using Search-Index since that's what has frameworkName

Like I said though guess if it works it works,

const firstTag = this.learningObject.tags[0];

// Check if tags are already objects with a name property
if (firstTag && typeof firstTag === 'object') {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if this tag being a type object would ever pass here, on objects-index tags are a string array of the tag ids, I don't see earlier in this file where learningObject.tags could've been changed to be something different. Could have missed it I guess, but can't tell if this code resolves them correctly cause I know with where the design left off it doesn't display tags on the learning object cards does it

Copy link
Contributor

@dsoto18 dsoto18 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just a couple comments but looks good to me

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants